package lt.laimis.shop.web.action;

import net.sourceforge.stripes.action.ActionBeanContext;

import java.util.List;
import java.util.Map;
import java.util.HashMap;
import java.util.ArrayList;

import lt.laimis.shop.service.product.Product;

/**
 * Created by IntelliJ IDEA.
 * User: laimis
 * Date: Jul 14, 2008
 * Time: 8:25:41 PM
 * To change this template use File | Settings | File Templates.
 */


public class ShopActionBeanContext extends ActionBeanContext {

    private Map<String, Object> sessionMap;

    public Map<String, Object> getSessionMap() {
        if (this.sessionMap == null) {
            this.sessionMap = ((Map) getRequest().getSession().getAttribute("shop_session_map"));
            if (this.sessionMap == null) {
                this.sessionMap = new HashMap();
                getRequest().getSession().setAttribute("shop_session_map", this.sessionMap);
            }
        }
        return this.sessionMap;

    }
}
